import BaseXform from '../base-xform';

class RelationshipXform extends BaseXform {
    render(xmlStream, model) {
        xmlStream.leafNode('Relationship', model);
    }

    parseXmlObject(node) {
        switch (node._name) {
            case 'Relationship':
                this.model = node._attributes;
                return true;
            default:
                return false;
        }
    }

    parseOpen(node) {
        switch (node.name) {
            case 'Relationship':
                this.model = node.attributes;
                return true;
            default:
                return false;
        }
    }

    parseText() {
    }

    parseClose() {
        return false;
    }
}

export default RelationshipXform;
